<div class="title">
      <h3>收信箱</h3>
      <ul>
            <li class="current"><?php echo CHtml::link('收件箱', array('pm/inbox'),array('title'=>'收件箱'))?></li>
            <li><?php echo CHtml::link('发件箱', array('pm/outbox'),array('title'=>'发件箱'))?></li>
      </ul>
</div>
<div class="main_content">
      <div class="send">
            <div class="send_tab">
                  <ul>
                        <li <?php if(!isset($_GET['c'])||$_GET['c']==1):?>class="hover"<?php endif;?>><?php echo CHtml::link('所有信件',array('pm/inbox','c'=>1),array('title'=>'所有信件'));?></li>
                        <li <?php if($_GET['c']==2):?>class="hover"<?php endif;?>><?php echo CHtml::link('未读信件',array('pm/inbox','isread'=>PM::PM_READ_STATUS_NO,c=>2),array('title'=>'未读信件'));?></li>
                        <li <?php if($_GET['c']==3):?>class="hover"<?php endif;?>><?php echo CHtml::link('垃圾信件',array('pm/inbox','s'=>PM::PM_STATUS_SPAMS,c=>3),array('title'=>'垃圾信件'));?></li>
                  </ul>
            </div>
            <table width="640" border="0" cellspacing="0" cellpadding="0">
                  <thead>
                        <tr>
                              <th width="60" style="text-align:left; padding-left:20px;">来自</th>
                              <th width="350" style="text-align:left; padding-left:20px;">话题</th>
                              <th width="120">时间</th>
                              <th width="70">选择</th>
                        </tr>
                  </thead>
                  <tbody>
                        <?php if($data['total_num']>0):;?>
                        <?php foreach($data['rows'] as $k=>$v):?>
                        <tr <?php if($v->is_read==PM::PM_READ_STATUS_YES):?>class='color' <?php endif;?>>
                              <td><?php $tmp = User::getUserById($v->from_uid); echo $tmp->nickname;?></td>
                              <td class="info_width"><a href="<?php echo  Yii::app()->urlManager->createUrl('pm/detail',array('id'=>$v->id,'ref'=>'2')); ?>" title="<?php echo nl2br(CHtml::encode($v->subject));?>"><?php echo nl2br(CHtml::encode($v->subject));?></a></td>
                              <td><?php echo substr($v->ctime,0,16);?></td>
                              <td class="center"><input type="checkbox" name="mid" value="<?php echo $v->id?>" /></td>
                        </tr>
                        <?php endforeach;?>
                  <?php else:?>
                        <tr><td colspan=3>收信箱无内容</td></tr>
                  <?php endif;?>
                  </tbody>
                  <tfoot>
                        <tr>
                              <td colspan="3" style="padding-right:10px;"><span class="delete" id='inbox'>删除</span></td>
                              <td><span>全选</span>
                                    <input type="checkbox" name="send_check" class="allcheck"/></td>
                              </tr>
                        </tfoot>
                  </table>
                  <div class="page">
                  <?php $this->widget('ZLinkPager', array('pages' => $data['pages'])); ?>
                  </div>
            </div>
      </div>